package com.label.Dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.label.Model.Do.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface UserMapper extends BaseMapper<User> {

    public List<User> getUserById(Long id);

    public List<User> getAllUserByAccount(String account);

    public User getOneUserByAccount(String account);

    public List<User> getUserByRole(@Param("roles") List<String> r_id);

    public Boolean saveUserRole(@Param("user") String u_id, @Param("roles") List<String> r_id);

    public Boolean delUserRole(String u_id);

}
